package cz.data.common.security;

import org.springframework.security.web.util.matcher.RequestMatcher;

import javax.servlet.http.HttpServletRequest;

public abstract class AbstractRequestMatcher implements RequestMatcher {

    @Override
    public boolean matches(HttpServletRequest request) {
        return doMatches(request);
    }

    protected abstract boolean doMatches(HttpServletRequest request);

    protected abstract void register(String method, String requestUrl);

    protected abstract void unRegister(String method, String requestUrl);
}
